package com.joplus.housekeeper.bean;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.ArrayList;
import java.util.List;

/**
 * author： ccm
 * time： 2017/7/4.
 * description：
 */

public  class Other implements Parcelable {


    /**
     * subject : 代排队
     * serId : ser14631097875211SNI
     * serOriginal : 0
     * chargeOriginal : 0
     * orderMoney : 1020
     * cardInfo : [{"key":"餐厅","value":"栖峰堂"},{"key":"时间","value":"2016-07-09 00:00","type":"datetime-local"},{"key":"人数","value":"2"}]
     * otherInfo : [{"key":"用户","value":""},{"key":"备注","value":""}]
     */

    private String subject;
    private String serId;
    private String serOriginal;
    private int chargeOriginal;
    private String orderMoney;


    /**
     * key : 餐厅
     * value : 栖峰堂
     */

    private List<CardInfoBean> cardInfo;
    /**
     * key : 用户
     * value :
     */

    private List<OtherInfoBean> otherInfo;
    /**
     * templateId : tplate1467872592680G9yq
     * orderPhone : 15056094638
     * serPrice : 1000
     * serCharge : 100
     * quantity : 2
     * orderType : event
     * isVip : 0
     * accountId : acc1467891847051a7oV
     * orderId : order14679481440466WSj
     * orderNo : CLUBMW1467948144046GRiU
     */

    private String templateId;
    private String orderPhone;
    private String serPrice;
    private String serCharge;
    private String quantity;
    private String orderType;
    private String isVip;
    private String accountId;
    private String orderId;
    private String orderNo;
    private String storedId;


    public String getStoredId() {
        return storedId;
    }

    public void setStoredId(String storedId) {
        this.storedId = storedId;
    }

    public String getSubject() {
        return subject;
    }

    public void setSubject(String subject) {
        this.subject = subject;
    }

    public String getSerId() {
        return serId;
    }

    public void setSerId(String serId) {
        this.serId = serId;
    }

    public String getSerOriginal() {
        return serOriginal;
    }

    public void setSerOriginal(String serOriginal) {
        this.serOriginal = serOriginal;
    }

    public int getChargeOriginal() {
        return chargeOriginal;
    }

    public void setChargeOriginal(int chargeOriginal) {
        this.chargeOriginal = chargeOriginal;
    }

    public String getOrderMoney() {
        return orderMoney;
    }

    public void setOrderMoney(String orderMoney) {
        this.orderMoney = orderMoney;
    }

    public List<CardInfoBean> getCardInfo() {
        return cardInfo;
    }

    public void setCardInfo(List<CardInfoBean> cardInfo) {
        this.cardInfo = cardInfo;
    }

    public List<OtherInfoBean> getOtherInfo() {
        return otherInfo;
    }

    public void setOtherInfo(List<OtherInfoBean> otherInfo) {
        this.otherInfo = otherInfo;
    }

    public String getTemplateId() {
        return templateId;
    }

    public void setTemplateId(String templateId) {
        this.templateId = templateId;
    }

    public String getOrderPhone() {
        return orderPhone;
    }

    public void setOrderPhone(String orderPhone) {
        this.orderPhone = orderPhone;
    }

    public String getSerPrice() {
        return serPrice;
    }

    public void setSerPrice(String serPrice) {
        this.serPrice = serPrice;
    }

    public String getSerCharge() {
        return serCharge;
    }

    public void setSerCharge(String serCharge) {
        this.serCharge = serCharge;
    }

    public String getQuantity() {
        return quantity;
    }

    public void setQuantity(String quantity) {
        this.quantity = quantity;
    }

    public String getOrderType() {
        return orderType;
    }

    public void setOrderType(String orderType) {
        this.orderType = orderType;
    }

    public String getIsVip() {
        return isVip;
    }

    public void setIsVip(String isVip) {
        this.isVip = isVip;
    }

    public String getAccountId() {
        return accountId;
    }

    public void setAccountId(String accountId) {
        this.accountId = accountId;
    }

    public String getOrderId() {
        return orderId;
    }

    public void setOrderId(String orderId) {
        this.orderId = orderId;
    }

    public String getOrderNo() {
        return orderNo;
    }

    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo;
    }

    public static class CardInfoBean implements Parcelable {
        private String key;
        private String value;

        public String getKey() {
            return key;
        }

        public void setKey(String key) {
            this.key = key;
        }

        public String getValue() {
            return value;
        }

        public void setValue(String value) {
            this.value = value;
        }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(this.key);
            dest.writeString(this.value);
        }

        public CardInfoBean() {
        }

        protected CardInfoBean(Parcel in) {
            this.key = in.readString();
            this.value = in.readString();
        }

        public static final Creator<CardInfoBean> CREATOR = new Creator<CardInfoBean>() {
            @Override
            public CardInfoBean createFromParcel(Parcel source) {
                return new CardInfoBean(source);
            }

            @Override
            public CardInfoBean[] newArray(int size) {
                return new CardInfoBean[size];
            }
        };
    }

    public static class OtherInfoBean implements Parcelable {
        private String key;
        private String value;

        public String getKey() {
            return key;
        }

        public void setKey(String key) {
            this.key = key;
        }

        public String getValue() {
            return value;
        }

        public void setValue(String value) {
            this.value = value;
        }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(this.key);
            dest.writeString(this.value);
        }

        public OtherInfoBean() {
        }

        protected OtherInfoBean(Parcel in) {
            this.key = in.readString();
            this.value = in.readString();
        }

        public static final Creator<OtherInfoBean> CREATOR = new Creator<OtherInfoBean>() {
            @Override
            public OtherInfoBean createFromParcel(Parcel source) {
                return new OtherInfoBean(source);
            }

            @Override
            public OtherInfoBean[] newArray(int size) {
                return new OtherInfoBean[size];
            }
        };
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(this.subject);
        dest.writeString(this.serId);
        dest.writeString(this.serOriginal);
        dest.writeInt(this.chargeOriginal);
        dest.writeString(this.orderMoney);
        dest.writeList(this.cardInfo);
        dest.writeList(this.otherInfo);
        dest.writeString(this.templateId);
        dest.writeString(this.orderPhone);
        dest.writeString(this.serPrice);
        dest.writeString(this.serCharge);
        dest.writeString(this.quantity);
        dest.writeString(this.orderType);
        dest.writeString(this.isVip);
        dest.writeString(this.accountId);
        dest.writeString(this.orderId);
        dest.writeString(this.orderNo);
        dest.writeString(this.storedId);

    }

    public Other() {
    }

    protected Other(Parcel in) {
        this.subject = in.readString();
        this.serId = in.readString();
        this.serOriginal = in.readString();
        this.chargeOriginal = in.readInt();
        this.orderMoney = in.readString();
        this.cardInfo = new ArrayList<CardInfoBean>();
        in.readList(this.cardInfo, CardInfoBean.class.getClassLoader());
        this.otherInfo = new ArrayList<OtherInfoBean>();
        in.readList(this.otherInfo, OtherInfoBean.class.getClassLoader());
        this.templateId = in.readString();
        this.orderPhone = in.readString();
        this.serPrice = in.readString();
        this.serCharge = in.readString();
        this.quantity = in.readString();
        this.orderType = in.readString();
        this.isVip = in.readString();
        this.accountId = in.readString();
        this.orderId = in.readString();
        this.orderNo = in.readString();
        this.storedId = in.readString();
    }

    public static final Parcelable.Creator<Other> CREATOR = new Parcelable.Creator<Other>() {
        @Override
        public Other createFromParcel(Parcel source) {
            return new Other(source);
        }

        @Override
        public Other[] newArray(int size) {
            return new Other[size];
        }
    };
}
